package com.example.communitypro.pojo;

import java.io.Serializable;

public class LabelRelation implements Serializable {
    private Integer relationNo;

    private Integer obNo;

    private Integer labelNo;

    private Integer obType;

    private static final long serialVersionUID = 1L;

    public Integer getRelationNo() {
        return relationNo;
    }

    public void setRelationNo(Integer relationNo) {
        this.relationNo = relationNo;
    }

    public Integer getObNo() {
        return obNo;
    }

    public void setObNo(Integer obNo) {
        this.obNo = obNo;
    }

    public Integer getLabelNo() {
        return labelNo;
    }

    public void setLabelNo(Integer labelNo) {
        this.labelNo = labelNo;
    }

    public Integer getObType() {
        return obType;
    }

    public void setObType(Integer obType) {
        this.obType = obType;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        LabelRelation other = (LabelRelation) that;
        return (this.getRelationNo() == null ? other.getRelationNo() == null : this.getRelationNo().equals(other.getRelationNo()))
            && (this.getObNo() == null ? other.getObNo() == null : this.getObNo().equals(other.getObNo()))
            && (this.getLabelNo() == null ? other.getLabelNo() == null : this.getLabelNo().equals(other.getLabelNo()))
            && (this.getObType() == null ? other.getObType() == null : this.getObType().equals(other.getObType()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getRelationNo() == null) ? 0 : getRelationNo().hashCode());
        result = prime * result + ((getObNo() == null) ? 0 : getObNo().hashCode());
        result = prime * result + ((getLabelNo() == null) ? 0 : getLabelNo().hashCode());
        result = prime * result + ((getObType() == null) ? 0 : getObType().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", relationNo=").append(relationNo);
        sb.append(", obNo=").append(obNo);
        sb.append(", labelNo=").append(labelNo);
        sb.append(", obType=").append(obType);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}